package org.dromara.business.domain.vo;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;

import org.dromara.business.domain.UserStaking;
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import cn.idev.excel.annotation.ExcelProperty;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;


/**
 * 用户质押记录视图对象 app_user_stakings
 *
 * @author Eric
 * @date 2025-09-05
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = UserStaking.class)
public class UserStakingVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 质押ID
     */
    @ExcelProperty(value = "质押ID")
    private Long id;

    /**
     * 用户ID
     */
    @ExcelProperty(value = "用户ID")
    private Long userId;
    private String walletAddress;

    /**
     * 产品ID
     */
    @ExcelProperty(value = "产品ID")
    private Long productId;
    private String productName;

    /**
     * 订单号
     */
    @ExcelProperty(value = "订单号")
    private String orderNo;

    /**
     * 质押金额
     */
    @ExcelProperty(value = "质押金额")
    private BigDecimal stakingAmount;

    /**
     * 日收益率（%）
     */
    @ExcelProperty(value = "日收益率", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "%=")
    private BigDecimal dailyRate;

    /**
     * 质押周期（天）
     */
    @ExcelProperty(value = "质押周期", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "天=")
    private Integer periodDays;

    /**
     * 预计总收益
     */
    @ExcelProperty(value = "预计总收益")
    private BigDecimal totalEarnings;

    /**
     * 已支付收益
     */
    @ExcelProperty(value = "已支付收益")
    private BigDecimal paidEarnings;

    /**
     * 剩余天数
     */
    @ExcelProperty(value = "剩余天数")
    private Integer remainingDays;

    /**
     * 开始日期
     */
    @ExcelProperty(value = "开始日期")
    private LocalDateTime startDate;

    /**
     * 结束日期
     */
    @ExcelProperty(value = "结束日期")
    private LocalDateTime endDate;

    /**
     * 最后返利日期
     */
    @ExcelProperty(value = "最后返利日期")
    private LocalDateTime lastRebateDate;
    private LocalDateTime createTime;

    /**
     * 状态
     */
    @ExcelProperty(value = "状态", converter = ExcelDictConvert.class)
    @ExcelDictFormat(dictType = "user_stakings_status")
    private Integer status;


}
